# Get the mididings and OSC stuffs
from mididings import *
from mididings.extra.osc import SendOSC

# Set up the OSC port 
#(you define it in non-mixer thanks to  "--osc-port=7587" option - no quotes)
port = 7587


run({
	CTRL: CtrlSplit(
		{
		20: Channel(1),
		21: Channel(1),
		22: Channel(1),
		23: Channel(1),		
		100: SendOSC(port, '/strip/git/Gain/Gain%20(dB)', lambda ev: ev.value / 127.0),
		101: SendOSC(port, '/strip/keys/Gain/Gain%20(dB)', lambda ev: ev.value / 127.0),
		102: SendOSC(port, '/strip/drum/Gain/Gain%20(dB)', lambda ev: ev.value / 127.0),
		103: SendOSC(port, '/strip/all/Gain/Gain%20(dB)', lambda ev: ev.value / 127.0),}),	
				
		
	PROGRAM: Channel(1),
	NOTE: ChannelFilter(1)
})
